<template>
	<view class="page index">
		<view class="form">
			<common-input title="备忘标题" placeholder="请填写备忘标题" v-model="noteForm.title" :borderBottom="false"></common-input>
			<common-input title="备忘日期" placeholder="请填写备忘日期" v-model="noteForm.date"></common-input>
			<view class="text">
				<view class="title">
					备忘内容
				</view>
				<textarea v-model="noteForm.content" placeholder="请输入备忘内容" placeholder-class="place"></textarea>
			</view>
			<update-file @update="updatefiles"></update-file>
		</view>
		<view class="footer">
			<button @click="saveNote">保存</button>
		</view>
	</view>
</template>

<script>
	import commonInput from "@/components/commonInput.vue"
	import updateFile from "@/components/updateFile.vue"
	export default{
		data() {
			return{
				noteForm:{
					title:'',
					date:'',
					content:''
				},
				file:[]
			}
		},
		components: {
			commonInput,
			updateFile
		},
		methods:{
			updatefiles(e){
				console.log(e,'===============')
			},
			saveNote(){
				console.log(this.noteForm)
			},
		}
	}
</script>

<style lang="scss" scoped>
	@import "@/common/style/customicons.scss";
	.index{
		padding: 24rpx 0;
		@include flex-c;
		.form{
			flex: 1 0 0;
			.text{
				border-bottom: 4rpx #e5e5e5 solid;
				padding: 12rpx 30rpx;
				.title{
					font-size: 28rpx;
					color: #101010;
					padding: 0 0 16rpx;
				}
				textarea{
					font-size: 28rpx;
					color: #909090;
					height: 125rpx;
				}
				.place{
					font-size: 28rpx;
					color: #909090;
				}
			}
		}
		.footer{
			flex: 0 0 auto;
			padding: 24rpx 130rpx;
			button{
				@include button;
				background-color: #198AFA;
				color: #fff;
				height: 60rpx;
				line-height: 60rpx;
				font-size: 28rpx;
				width: 100%;
			}
		}
	}
</style>